/**
 *  (c)
 *
 *
 *
 *
 */

package org.zw.zcommon.zcpage.model;


import java.io.Serializable;
import java.util.List;

/**
 * 分页工具类
 *
 * @author singleton-zw 2321277858@qq.com
 */


public class ZCPageDataModel<T> implements Serializable {
    private static final long serialVersionUID = 1L;

    private int total;

    private List<T> list;
    private Integer page;
    private Integer size;



    /**
     * 分页
     * @param list   列表数据
     * @param total  总记录数
     */
    public ZCPageDataModel(List<T> list, long total, Integer page, Integer size) {
        this.list = list;
        this.total = (int)total;
        this.page = page;
        this.size = size;
    }

    public int getTotal() {
        return total;
    }

    public void setTotal(int total) {
        this.total = total;
    }

    public List<T> getList() {
        return list;
    }

    public void setList(List<T> list) {
        this.list = list;
    }

    public Integer getPage() {
        return page;
    }

    public void setPage(Integer page) {
        this.page = page;
    }

    public Integer getSize() {
        return size;
    }

    public void setSize(Integer size) {
        this.size = size;
    }
}